<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
     <meta charset="UTF-8">
    <title>商品列表</title>
    <!-- 引入 Bootstrap 的 CSS 文件 -->
    <link href="https://cdn.jsdelivr.net/npm/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet">
</head>
<body>
	<div  class="container">
	    <h1>商品列表</h1>
	    <table class="table table-striped">
	        <thead>
	            <tr>
	                <th>ID</th>
	                <th>名称</th>
	                <th>价格</th>
	                <th>描述</th>
	            </tr>
	        </thead>
	        <tbody>
	            <tr th:each="product : ${products}">
	                <td th:text="${product.id}"></td>
	                <td th:text="${product.name}"></td>
	                <td th:text="${product.price}"></td>
	                <td th:text="${product.description}"></td>
	            </tr>
	        </tbody>
	    </table>
	 </div>
</body>
</html>